package com.ruoyi.web.controller.system;

import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.system.service.ISysUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

/**
 * 通讯录信息
 */
@RestController
@RequestMapping("/system/addressbook")
public class SysAddressBookController extends BaseController {

    @Autowired
    private ISysUserService userService;

    /**
     * 获取通讯录列表
     */
    @GetMapping("/list")
    public AjaxResult list() {
        List<Map<String, Object>> list = userService.selectAddressBookList();
        return success(list);
    }
}